Response variable = vit D
Explanatory variables = age, bmi, hypert, & diab
##
## Call:
## lm(formula = vitD ~ Age + BMI + Hypert + Diab, data = d)
##
## Residuals:
## Min 1Q Median 3Q Max
## -47.910 -11.527 -0.912 10.282 86.768
##
## Coefficients:
## Estimate Std. Error t value Pr(>|t|)
## (Intercept) 77.80754 2.25265 34.540 < 2e-16 ***
## Age -0.19993 0.04896 -4.083 4.59e-05 ***
## BMI -0.32273 0.06663 -4.844 1.36e-06 ***
## Hypert1 0.99618 1.32710 0.751 0.453
## Diab1 -1.43195 0.88457 -1.619 0.106
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Residual standard error: 17.5 on 2205 degrees of freedom
## Multiple R-squared: 0.02937, Adjusted R-squared: 0.02761
## F-statistic: 16.68 on 4 and 2205 DF, p-value: 1.785e-13
The explanatory variables, together, explain a negligible amount of the variance in Vit D (see R-squared). When controlling for the other variables, both age and BMI have a negative and signficiant relation with Vit D (see column "Pr(>|t|)").
Response variable = mean Vit D
Explanatory variables = Deaths per 100,000, Altitude, Latitude, & Ethnicity
##
## Call:
## lm(formula = mean_vitD ~ Deaths_ht + Alt + Lat + Ethnicity, data = df_mun)
##
## Residuals:
## Min 1Q Median 3Q Max
## -15.2271 -3.7962 0.0926 3.3457 17.7142
##
## Coefficients:
## Estimate Std. Error t value Pr(>|t|)
## (Intercept) 88.8672378 4.0147662 22.135 < 2e-16 ***
## Deaths_ht -0.0655478 0.0284492 -2.304 0.0227 *
## Alt -0.0063961 0.0005499 -11.631 < 2e-16 ***
## Lat -0.8625039 0.1595556 -5.406 2.62e-07 ***
## Ethnicity -0.0298645 0.0383426 -0.779 0.4373
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Residual standard error: 5.544 on 144 degrees of freedom
## Multiple R-squared: 0.5678, Adjusted R-squared: 0.5558
## F-statistic: 47.3 on 4 and 144 DF, p-value: < 2.2e-16
Explanatory variables, together, explain 30% of the variance in Vit D at municipal scale. When controlling for other variables, each variable shows a negative relation with vit D, but only deaths per 100,000, altitude, and latitude are significant. If ethnicity is removed from the model, results are almost the same in terms of coefficients, their signs, and R2.